import { createApp } from 'vue'
import App from './App.vue'
import router from './router';

// 引入 Element Plus
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
// 引入图标
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

// 导入全局样式
import '@/assets/styles/main.scss'

//引入中文语言包
import zhCn from 'element-plus/es/locale/lang/zh-cn'

const app = createApp(App)
// 注册所有图标
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}


app.use(router)
app.use(ElementPlus, {
  locale: zhCn, // 设置语言为中文
})
app.mount('#app')
